package design.pattern.structural.composite;

public class Test {
    public static void main(String[] args) {
        Plate plate = new Plate();

        plate.add(new Apple());
        plate.add(new Pear());
        plate.add(new Banana());

        for (int i = 0; i < 3; i++) {
            plate.eat();
        }
    }
}
